<template>
  <div class="dashboard-container">
    <div class="container">
      <div class="waterSupplyBox">
        <div class="waterSupplyBoxTop">
          <div class="">
            <div class="todayWater">
              待发货订单
            </div>
            <div class="todayT">
              <div class="todayTL">
                <!-- 613 -->
                {{order.receiptConfirmedNumber}}
              </div>
            </div>
          </div>
          <div>
            <img src="../../../assets/headImg.png" alt="">
          </div>
        </div>
      </div>
      <div class="waterSupplyBox waternth_2">
        <div class="waterSupplyBoxTop">
          <div class="">
            <div class="todayWater">
              待收货订单
            </div>
            <div class="todayT">
              <div class="todayTL">
                <!-- 326 -->
                {{order.deliverdNumber}}
              </div>
            </div>
          </div>
          <div>
            <img src="../../../assets/headImg.png" alt="">
          </div>
        </div>
      </div>
      <div class="waterSupplyBox waternth_3">
        <div class="waterSupplyBoxTop">
          <div class="">
            <div class="todayWater">
              已完成订单
            </div>
            <div class="todayT">
              <div class="todayTL">
                <!-- 613 -->
                {{order.recivedNumber}}
              </div>
            </div>
          </div>
          <div>
            <img src="../../../assets/headImg.png" alt="">
          </div>
        </div>
      </div>
      <div class="waterSupplyBox">
        <div class="waterSupplyBoxTop">
          <div class="">
            <div class="todayWater">
              总订单
            </div>
            <div class="todayT">
              <div class="todayTL">
                <!-- 613 -->
                {{order.allOrderNumber}}
              </div>
            </div>
          </div>
          <div>
            <img src="../../../assets/headImg.png" alt="">
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
import { mapGetters } from "vuex";

export default {
  name: 'Dashboard',
  data: function(){
    return {
      order:{}
    }
  },
  computed: {
    ...mapGetters(['name']),
  },
  mounted() {
    this.getOrder()
  },
  methods: {
    getOrder(){
      this.$api.procurementOrderList({status:'6'}).then(res => {
        this.order = res
        console.log(res)
      })
    }
  }
}
</script>

<style lang="scss" scoped>
.dashboard {
  &-container {
    width: 100%;
    margin-bottom: 24px;
  }
}
  .waternth_2{
   margin: 0 12px 0 24px;
  }
  .waternth_3{
   margin: 0 24px 0 12px;
  }
.container{
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  .waterSupplyBox{
    width: 100%;
    height: 118px;
    background: linear-gradient(270deg, #C773FD 0%, #4669FE 100%);
    box-shadow: 0px 32px 80px -40px rgba(187, 114, 253, 0.5);
    border-radius: 2px;
    .waterSupplyBoxTop{
      display: flex;
      flex-direction: row;
      align-items: center;
      justify-content: space-between;
      padding: 24px 0 0 24px;
      .todayWater{
        font-size: 16px;
        font-family: MicrosoftYaHei;
        color: #FFFFFF;
      }
      .todayT{
        margin-top: 10px;
        display: flex;
        flex-direction: row;
        color: #FFFFFF;
        .todayTL{
          font-size: 34px;
          font-family: MicrosoftYaHei-Bold, MicrosoftYaHei;
          font-weight: bold;

        }
        .todayTR{
          font-size: 20px;
          margin-left: 3px;
          margin-top: 20px;
        }
        .todayTR1{
          font-size: 20px;
          margin-left: 3px;
          margin-top: 20px;
        }
      }
      img{
        width: 62px;
        height: 62px;
        margin-right: 25px;
      }
    }
    .waterSupplyBoxButt{
      border-top: 1px solid #FFFFFF;
      display: flex;
      flex-direction: row;
      justify-content: space-between;
      align-items: center;
      .waterSupplyBoxButtL{
        font-size: 14px;
        color: #FFFFFF;
        padding: 15px 0 0 24px;
      }
      .waterSupplyBoxButtR{
        font-size: 14px;
        color: #FFFFFF;
        padding: 15px 24px 0 0;
        img{
          width: 12px;
          height: 6.28px;
        }
      }
    }
  }
  .waterSupplyBox:nth-child(2){
    background: linear-gradient(270deg, #606AF1 0%, #3CADF6 100%);
    box-shadow: 0px 32px 80px -40px #4F8AF4;
    border-radius: 2px;
  }
  .waterSupplyBox:nth-child(3){
    background: linear-gradient(270deg, #F09D5B 0%, #EA647E 100%);
    box-shadow: 0px 32px 50px -40px rgba(237, 126, 111, 0.5);
    border-radius: 2px;
  }
  .waterSupplyBox:nth-child(4){
    background: linear-gradient(270deg, #A8E25F 0%, #40D799 100%);
    box-shadow: 0px 30px 50px -40px rgba(117, 220, 123, 0.5);
    border-radius: 2px;
  }
  .waterSupplyBox:nth-child(4) .waterSupplyBoxButt{
    padding-left: 24px;
  }
  .waterSupplyBox:nth-child(4) .todayT .todayTR{
    margin-top: 13px;
  }
}
</style>
